﻿<UserControl  
    x:Class="SQLServerOptimizer.PL.WPF.SeverityList"
   
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
               xmlns:de="clr-namespace:SQLServerOptimizer.PL.WPF"
             mc:Ignorable="d" >
         <UserControl.Resources>

    <DataTemplate x:Key="severitytemp" DataType="severities" >
        <StackPanel  Orientation="Horizontal" Height="15" Margin="0,-4,0,0">
                <CheckBox  IsChecked="{Binding Path=ischecked}" Tag="{Binding Path=name}" Unchecked="CheckBox_Unchecked" Checked="CheckBox_Checked" />
            <TextBlock  Margin="10,0,0,0" FontWeight="bold"  Foreground="{Binding Path=color}" Text="{Binding Path=name}"/>

        </StackPanel>
    </DataTemplate>
    </UserControl.Resources>

    <ListBox ScrollViewer.CanContentScroll="False" ScrollViewer.VerticalScrollBarVisibility="Disabled" x:Name="SeverityLB" ItemTemplate="{StaticResource severitytemp}" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" >
    	  <ListBox.Resources>
		  <Style TargetType="ListBox" />
		 </ListBox.Resources>
</ListBox>
   
</UserControl>